package com.qst.controller;

import com.qst.domain.VipExpensesRecord;
import com.qst.dto.Result;
import com.qst.service.IVipExpensesRecordService;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

@RestController
@RequestMapping("/expensesRecord")
public class VipExpensesRecordController {
    @Resource
    private IVipExpensesRecordService vipExpensesRecordService;


    @PostMapping
    public Result addExpensesRecord(@RequestBody VipExpensesRecord vipExpensesRecord){
        return vipExpensesRecordService.saveExpensesRecord(vipExpensesRecord);
    }

    @PutMapping
    public Result bookkeeping(@RequestBody VipExpensesRecord vipExpensesRecord){
        return vipExpensesRecordService.bookkeeping(vipExpensesRecord);
    }
}
